#coding:utf8
import os

def trans(cur, handler):
    f = os.listdir(cur)
    for i in f:
        name = os.path.join(cur, i)
        if os.path.isdir(name):
            trans(name, handler)    
        else:
            handler(name)

def changeGUID(name):
    if name.find('.prefab') != -1:
        of = open(name).readlines()
        nc = ''
        for l in of:
            nc += l.replace('d8d5a130275244907a5cdac0eded3630', '4eaa492ec72a57543b3ace7c81409998')
        wf = open(name, 'w')
        wf.write(nc)
        wf.close()

trans('.', changeGUID)

